from flask import Flask

app = Flask(__name__)


# <username> 就是动态路由参数
@app.route("/user/<username>")
def user_profile(username):
    return f"用户名:{username}"


@app.route("/post/<int:post_id>")
def show_post(post_id):
    return f"post_id:{post_id}"


if __name__ == "__main__":
    app.run()
